Look for icons in XDG_DATA_DIRS/pixmaps. (#165950, Thomas Zajic)
authorMatthias Clasen <mclasen@redhat.com>
Wed, 2 Feb 2005 04:31:21 +0000 (04:31 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Wed, 2 Feb 2005 04:31:21 +0000 (04:31 +0000)
2005-02-01  Matthias Clasen  <mclasen@redhat.com>

* gtk/gtkicontheme.c (gtk_icon_theme_init): Look for icons
in XDG_DATA_DIRS/pixmaps.  (#165950, Thomas Zajic)

ChangeLog
ChangeLog.pre-2-10
ChangeLog.pre-2-8
gtk/gtkicontheme.c

index 2d8b4775f200049e4f977d40170662bfc462fa70..601dda3d8e60cbbce93f5b67116d41f63c58e220 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2005-02-01  Matthias Clasen  <mclasen@redhat.com>
 
+       * gtk/gtkicontheme.c (gtk_icon_theme_init): Look for icons
+       in XDG_DATA_DIRS/pixmaps.  (#165950, Thomas Zajic)
+
        * gtk/gtkwindow.c (gtk_window_set_icon_name): Set info->icon_list
        to NULL after freeing it.  (#165800, Damon Chaplin)
 
index 2d8b4775f200049e4f977d40170662bfc462fa70..601dda3d8e60cbbce93f5b67116d41f63c58e220 100644 (file)
@@ -1,5 +1,8 @@
 2005-02-01  Matthias Clasen  <mclasen@redhat.com>
 
+       * gtk/gtkicontheme.c (gtk_icon_theme_init): Look for icons
+       in XDG_DATA_DIRS/pixmaps.  (#165950, Thomas Zajic)
+
        * gtk/gtkwindow.c (gtk_window_set_icon_name): Set info->icon_list
        to NULL after freeing it.  (#165800, Damon Chaplin)
 
index 2d8b4775f200049e4f977d40170662bfc462fa70..601dda3d8e60cbbce93f5b67116d41f63c58e220 100644 (file)
@@ -1,5 +1,8 @@
 2005-02-01  Matthias Clasen  <mclasen@redhat.com>
 
+       * gtk/gtkicontheme.c (gtk_icon_theme_init): Look for icons
+       in XDG_DATA_DIRS/pixmaps.  (#165950, Thomas Zajic)
+
        * gtk/gtkwindow.c (gtk_window_set_icon_name): Set info->icon_list
        to NULL after freeing it.  (#165800, Damon Chaplin)
 
index ca6ef338f3ec19b1e5317c56aa8e3c324329e0fd..77b6c8c7c0eb7ecba99187364c9fceace3d25751 100644 (file)
@@ -568,10 +568,7 @@ gtk_icon_theme_init (GtkIconTheme *icon_theme)
   xdg_data_dirs = g_get_system_data_dirs ();
   for (i = 0; xdg_data_dirs[i]; i++) ;
 
-  priv->search_path_len = i + 2;
-#ifdef G_OS_UNIX
-  priv->search_path_len++;
-#endif
+  priv->search_path_len = 2 * i + 2;
   
   priv->search_path = g_new (char *, priv->search_path_len);
   
@@ -582,9 +579,8 @@ gtk_icon_theme_init (GtkIconTheme *icon_theme)
   for (j = 0; xdg_data_dirs[j]; j++) 
     priv->search_path[i++] = g_build_filename (xdg_data_dirs[j], "icons", NULL);
 
-#ifdef G_OS_UNIX
-  priv->search_path[i++] = g_strdup ("/usr/share/pixmaps");
-#endif
+  for (j = 0; xdg_data_dirs[j]; j++) 
+    priv->search_path[i++] = g_build_filename (xdg_data_dirs[j], "pixmaps", NULL);
 
   priv->themes_valid = FALSE;
   priv->themes = NULL;